22
Is it possible to let user choose the inserting mode, when he presses Insert key ( method 1 )
#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := "00:00"
		oMaskEdit:Text := "12:3"
		oMaskEdit:AllowToggleInsertMode := .T.
		oMaskEdit:InsertMode := 1/*exEditOvertypeMode*/

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
21
Does your control support overtype mode ( method 2 )

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := "00:00;;;overtype"
		oMaskEdit:Text := "12:3"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
20
Does your control support overtype mode ( method 1 )

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:InsertMode := 1/*exEditOvertypeMode*/
		oMaskEdit:Mask := "00:00"
		oMaskEdit:Text := "12:3"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
19
How can I change the colors to show a read only field

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:SetProperty("ForeColorReadOnly",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
		oMaskEdit:SetProperty("BackColorReadOnly",AutomationTranslateColor( GraMakeRGBColor  ( { 0,0,0 } )  , .F. ))
		oMaskEdit:ReadOnly := .T.
		oMaskEdit:Text := "text"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
18
How can I lock or make read only the field (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:ReadOnly := .T.
		oMaskEdit:Text := "text"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
17
How can I lock or make read only the field (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := "*;;;readonly"
		oMaskEdit:Text := "text"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
16
Is it possible to mask a password field (method 2)
#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Right := .T.
		oMaskEdit:Text := "text"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
15
Is it possible to right align field (method 1)
#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := "*;;;right"
		oMaskEdit:Text := "text"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
14
Is it possible to mask a password field (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Password := .T.
		oMaskEdit:Text := "password"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
13
Is it possible to mask a password field (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := "*;;;password"
		oMaskEdit:Text := "password"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
12
How can I mask an integer within a range

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := "{1950,2050}"
		oMaskEdit:Text := Transform(1979,"")

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
11
How can I mask an integer value with no grouping support

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := ";;;float,grouping=,decimal=,digits=0,select=1"
		oMaskEdit:Text := Transform(12345.67,"")

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
10
How can I mask an integer value (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := "-#####;;;float,select=1"
		oMaskEdit:Text := Transform(-12345.67,"")

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
9
How can I mask an integer value (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := ";;;float,decimal=,digits=0,select=1"
		oMaskEdit:Text := Transform(12345.67,"")

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
8
How can I specify the number of digits when masking a float (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := "###.#;;;float,select=1"
		oMaskEdit:Text := Transform(12345.67,"")

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
7
How can I specify the number of digits when masking a float (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := ";;;float,select=1,digits=1"
		oMaskEdit:Text := Transform(12345.67,"")

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
6
How do I mask a positive, floating point numbers support, including grouping of digits

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := ";;;float,select=1,negative=0"
		oMaskEdit:Text := Transform(-12345.67,"")

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
5
How do I mask a floating point numbers support, with a different decimal character

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := ";;;float,grouping= ,decimal=\,,select=1"
		oMaskEdit:Text := "12345,67"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
4
How do I mask a floating point numbers support, excluding grouping of digits

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := ";;;float,grouping=,select=1"
		oMaskEdit:Text := Transform(12345.67,"")

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
3
How do I mask a floating point numbers support, including grouping of digits

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:Mask := ";;;float,select=1"
		oMaskEdit:Text := Transform(12345.67,"")

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
2
How can I change the control's foreground color

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:SetProperty("ForeColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
		oMaskEdit:Text := "aka"

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
1
How can I change the control's background color

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oMaskEdit

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oMaskEdit := XbpActiveXControl():new( oForm:drawingArea )
	oMaskEdit:CLSID  := "Exontrol.MaskEdit.1" /*{43F80262-F652-11D3-AD39-00C0DFC59237}*/
	oMaskEdit:create(,, {10,60},{610,370} )

		oMaskEdit:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN